<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>TinyMCE Compressor PHP</title>
<link href="css/screen.css" rel="stylesheet" type="text/css" />
</head>
<body>

<h2>TinyMCE Compressor PHP</h2>

<h3>About</h3>
<p>
TinyMCE Compressor gzips all javascript files in TinyMCE to a single streamable file. This makes the overall download sice 75% smaller and the number of requests will also be reduced.
The overall initialization time for TinyMCE will be reduced dramaticly if you use this script.
</p>

<h3>Installation</h3>
<p>
Here is a step by step list on how to install the GZip compressor.
</p>

<ol>
	<li>Copy the tiny_mce_gzip.js and tiny_mce_gzip.php to the tiny_mce directory. The same directory that contains the tiny_mce.js file.</li>
	<li>Remove the current script tag. &lt;script type="text/javascript" src="tinymce/jscripts/tiny_mce/tiny_mce.js"&gt;&lt;/script&gt;</li>
	<li>Add the new new GZip script &lt;script type="text/javascript" src="tinymce/jscripts/tiny_mce/tiny_mce_gzip.js"&gt;&lt;/script&gt;.</li>
	<li>Add the new GZip initialization call that will tell the compressor what to include in the output. This should be the sum of all and themes, plugins contained on page.</li>
</ol>

<h3>Example of initialization</h3>
<p>The example below will pack both themes and all plugins into one file/steam. Remove the things you don't need or add you custom plugins to the settings below. Remember that the tinyMCE_GZ.init call must be placed in <strong>it's own script tag.</strong></p>
<pre>
&lt;script type="text/javascript" src="tinymce/jscripts/tiny_mce/tiny_mce_gzip.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript"&gt;
tinyMCE_GZ.init({
	plugins : 'style,layer,table,save,advhr,advimage,advlink,emotions,iespell,insertdatetime,preview,media,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras',
	themes : 'simple,advanced',
	languages : 'en',
	disk_cache : true,
	debug : false
});
&lt;/script&gt;
&lt;!-- Needs to be seperate script tags! --&gt;
&lt;script type="text/javascript"&gt;
tinyMCE.init({
	.. your normal init ..
});
&lt;/script&gt;
</pre>

<h3>Troubleshooting</h3>
<p>The GZip compressor can fail to load if the server has odd settings or is missing the required support for it to function. To see compilation errors or other problems we suggest that you use HTTP debugging tools like <a href="http://www.fiddlertool.com/fiddler/">HTTP Fiddler</a> or point you browser directly to the GZip file.</p>
<p>Consult the changelog of this script and make sure that you use the latest version of TinyMCE. These two parts are pretty much tied together so there is no guarantee that it will work with older versions of TinyMCE.</p>
<p>Visit the <a href="http://tinymce.moxiecode.com/forum/">TinyMCE forum</a> for help with the TinyMCE Gzip Compressor.</p>

<h3>License notice</h3>
<p>
This library is under LGPL license but it uses a GPL:ed third party library for the gzip compression.
This third party library can be used in commercial applications. Review the&quot;ICSharpCode.SharpZipLib_Readme.rtf&quot; for details.
</p>

</body>
</html>
